import request from '@/utils/request'
// 获取社群列表
export function getSocialLists(query) {
  return request({
    url: '/social/lists',
    method: 'get',
    params: query
  })
}
// 获取管理员
export function getManager(data) {
  return request({
    url: '/social/getManager',
    method: 'post',
    data
  })
}
// 保存社群数据
export function saveSocialRoom(data) {
  return request({
    url: '/social/saveRoom',
    method: 'post',
    data
  })
}
// 根据社群 id 获取社群数据
export function getSocialRoomDetail(id) {
  return request({
    url: '/social/getRoomDetail/' + id,
    method: 'post'
  })
}
// 根据社群 id 获取社群成员
export function getSocialRoomMember(query) {
  return request({
    url: '/social/getMember',
    method: 'get',
    params: query
  })
}

export function getUserByKey(data) {
  return request({
    url: '/social/getUserByKey',
    method: 'post',
    data
  })
}

export function getUserByCompanyId() {
  return request({
    url: '/social/getAllUser/',
    method: 'post'
  })
}

export function getActivityByCompanyId() {
  return request({
    url: '/social/getAllActivity/',
    method: 'post'
  })
}

export function getCourseByCompanyId() {
  return request({
    url: '/social/getAllCourse/',
    method: 'post'
  })
}

export function getColumnByCompanyId() {
  return request({
    url: '/social/getAllColumn/',
    method: 'post'
  })
}
export function changeSocialStatus(data, srId) {
  return request({
    url: '/social/changeSocialStatus/' + srId,
    method: 'post',
    data
  })
}
// 将用户加入黑名单或者溢出黑名单
export function changeMemberStatus(data, srmId) {
  return request({
    url: '/social/changeMemberStatus/' + srmId,
    method: 'post',
    data
  })
}
// 解散社群
export function deleteSocialRoom(srId) {
  return request({
    url: '/social/deleteSocialRoom/' + srId,
    method: 'post'
  })
}
// 获取社群的讲师
export function getSocialLecturer(srId) {
  return request({
    url: '/social/getSocialLecturer/' + srId,
    method: 'post'
  })
}
// 保存社群的讲师
export function saveLecturer(srId, data) {
  return request({
    url: '/social/saveLecturer/' + srId,
    method: 'post',
    data
  })
}

export function SetTeacher(query) {
  return request({
    url: '/Live/SetTeacher',
    method: 'get',
    params: query
  })
}

export function classList(query) {
  return request({
    url: '/Live/classList',
    method: 'get',
    params: query
  })
}

export function classSet(data) {
  return request({
    url: '/Live/classSet',
    method: 'post',
    data
  })
}

export function classStaus(query) {
  return request({
    url: '/Live/classStaus',
    method: 'get',
    params: query
  })
}
